#ifndef ONEWIDGET_H
#define ONEWIDGET_H

#include <QWidget>
#include<QTimer>
#include<QList>
QT_BEGIN_NAMESPACE
class QLabel;
QT_END_NAMESPACE

class TargetSheet;
#include<QVBoxLayout>
#include<QSpacerItem>

#include<QPointF>
#include"targetsheet.h"
#include "config/constvariable.h"

class OneWidget :public QWidget
{
  Q_OBJECT

public:
  explicit OneWidget(double size,QWidget *parent = nullptr);
~OneWidget();
  //创建布局
  void create(double labelXY);

  //实时更新大小
  void setSize(double width);

  void getMySignal();

  void addHoles(const QPointF& point);

  void clearHoles();

private slots:


signals:

  void mySignal(double);

  void mySignalHoles(const QList<QPointF>&  msg);


private:
  TargetSheet *targetSheet = nullptr;

  QTimer m_Timer;

  double scaleBody = 1;

  QList<QPointF>   onlyHoleList;
public:
  QLabel *labelSum = nullptr;
  QLabel *labelState = nullptr;

};

#endif // ONEWIDGET_H
